import request from '@/utils/request';
import { other } from './prefix';

const dmodelisManage = {
  // 查询3dmodle列表
  get3dmodle(params) {
    return request.get(other + '/3dmodle', { params });
  },
  // 创建3dmodle
  set3dmodle(params) {
    return request.post(other + '/3dmodle', params);
  },
  // 更新3dmodle
  upd3dmodle(id, params) {
    return request.post(other + '/3dmodle/' + id, params);
  },
  // 删除3dmodle
  del3dmodle(id) {
    return request.delete(other + '/3dmodle/' + id);
  },
  // 上传3dmodle图片
  set3dmodleImage(id, params) {
    return request.post(other + '/3dmodle/' + id + '?op=upload_file&name=title_page', params);
  },
  // 上传模型和下载模型
  setUpload3dModel(id, params) {
    return request.post(other + '/upload_data?op=upload_3d_model&stadium_id=' + id, params);
  },
};

export default dmodelisManage;
